package com.example.threaddemo.reference;

/**
 * 强引用
 */
public class StrongReferenceDemo {
    public static void main(String[] args) {
        Object o1 = new Object();
        Object o2 = o1;

        o1 = null;
        //手动GC
        System.gc();
        System.out.println(o2);
    }
}
